package ${domain.packageName};

import com.baomidou.mybatisplus.annotation.*;
import java.io.Serializable;
<#list tableClass.importList as fieldType>${"\n"}import ${fieldType};</#list>
import lombok.Data;
import lombok.experimental.Accessors;
import java.time.LocalDateTime;

/**
 * ${tableClass.remark!}
 * @author ${author!}
 * @TableName ${tableClass.tableName}
 * @createDate ${.now?string('yyyy-MM-dd HH:mm:ss')}
 */
@Data
@Accessors(chain = true)
@TableName("${tableClass.tableName}")
public class ${tableClass.shortClassName} implements Serializable {

<#list tableClass.pkFields as field>
    /**
     * ${field.remark!}
     */
    @TableId(value = COL_${field.columnName?upper_case} ,type = IdType.AUTO)
    private <#if field.jdbcType == 'TIMESTAMP' >LocalDateTime<#else>${field.shortTypeName}</#if> ${field.fieldName};

</#list>
<#list tableClass.baseBlobFields as field>
    /**
     * ${field.remark!}
     */
    @TableField(value = COL_${field.columnName?upper_case})<#if "${field.remark!}"?contains("逻辑删除")>${"\n    "}@TableLogic</#if>
    private <#if field.jdbcType == 'TIMESTAMP' >LocalDateTime<#else>${field.shortTypeName}</#if> ${field.fieldName};

</#list>

<#list tableClass.allFields as field>
    /**
     * ${field.remark!}
     */
    public static final String COL_${field.columnName?upper_case} = "${field.columnName}";

</#list>
    @TableField(exist = false)
    static final long serialVersionUID = 1L;
}
